package com.ruoyi.system.domain;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

import java.time.LocalDateTime;
import java.util.Objects;

/**
 * 【请填写功能名称】对象 orderqa_info
 *
 * @author ruoyi
 * @date 2025-02-12
 */
@Data
@ApiModel("无纸化订单质检信息对象 orderqa_info")
public class OrderqaInfo
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty("主键")
    private Long id;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("订单号")
    private String orderNo;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("工厂")
    private String plant;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("物料")
    private String material;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("物料描述")
    private String materialDesc;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("规格")
    private String itemSpec;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("下限")
    private String lower;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("上限")
    private String upper;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("单位")
    private String uom;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("单位描述")
    private String unit;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("面板")
    private String panel;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    @ApiModelProperty("是否启用")
    private Long isEnable;

    /** 检验结果 */
    @Excel(name = "检验结果")
    @ApiModelProperty("检验结果")
    private String result;

    /** 检查者 */
    @Excel(name = "检查者")
    @ApiModelProperty("检查者")
    private String checker;
    @Excel(name = "创建时间")
    @ApiModelProperty("创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    @TableField(value = "createtime",fill = FieldFill.INSERT)
    private LocalDateTime createTime;


    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }
    public void setOrderNo(String orderNo)
    {
        this.orderNo = orderNo;
    }

    public String getOrderNo()
    {
        return orderNo;
    }
    public void setPlant(String plant)
    {
        this.plant = plant;
    }

    public String getPlant()
    {
        return plant;
    }
    public void setMaterial(String material)
    {
        this.material = material;
    }

    public String getMaterial()
    {
        return material;
    }
    public void setMaterialDesc(String materialDesc)
    {
        this.materialDesc = materialDesc;
    }

    public String getMaterialDesc()
    {
        return materialDesc;
    }
    public void setItemSpec(String itemSpec)
    {
        this.itemSpec = itemSpec;
    }

    public String getItemSpec()
    {
        return itemSpec;
    }
    public void setLower(String lower)
    {
        this.lower = lower;
    }

    public String getLower()
    {
        return lower;
    }
    public void setUpper(String upper)
    {
        this.upper = upper;
    }

    public String getUpper()
    {
        return upper;
    }
    public void setUom(String uom)
    {
        this.uom = uom;
    }

    public String getUom()
    {
        return uom;
    }
    public void setUnit(String unit)
    {
        this.unit = unit;
    }

    public String getUnit()
    {
        return unit;
    }
    public void setPanel(String panel)
    {
        this.panel = panel;
    }

    public String getPanel()
    {
        return panel;
    }
    public void setIsEnable(Long isEnable)
    {
        this.isEnable = isEnable;
    }

    public Long getIsEnable()
    {
        return isEnable;
    }
    public void setResult(String result)
    {
        this.result = result;
    }

    public String getResult()
    {
        return result;
    }
    public void setChecker(String checker)
    {
        this.checker = checker;
    }

    public String getChecker()
    {
        return checker;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("orderNo", getOrderNo())
                .append("plant", getPlant())
                .append("material", getMaterial())
                .append("materialDesc", getMaterialDesc())
                .append("itemSpec", getItemSpec())
                .append("lower", getLower())
                .append("upper", getUpper())
                .append("uom", getUom())
                .append("unit", getUnit())
                .append("panel", getPanel())
                .append("isEnable", getIsEnable())
                .append("result", getResult())
                .append("checker", getChecker())
                .append("createtime", getCreateTime())
                .toString();
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof OrderqaInfo)) return false;

        OrderqaInfo that = (OrderqaInfo) o;

        if (getOrderNo() != null ? !getOrderNo().equals(that.getOrderNo()) : that.getOrderNo() != null) return false;
        if (getPlant() != null ? !getPlant().equals(that.getPlant()) : that.getPlant() != null) return false;
        if (getMaterial() != null ? !getMaterial().equals(that.getMaterial()) : that.getMaterial() != null)
            return false;
        if (getMaterialDesc() != null ? !getMaterialDesc().equals(that.getMaterialDesc()) : that.getMaterialDesc() != null)
            return false;
        if (getItemSpec() != null ? !getItemSpec().equals(that.getItemSpec()) : that.getItemSpec() != null)
            return false;
        if (getLower() != null ? !getLower().equals(that.getLower()) : that.getLower() != null) return false;
        if (getUpper() != null ? !getUpper().equals(that.getUpper()) : that.getUpper() != null) return false;
        if (getUom() != null ? !getUom().equals(that.getUom()) : that.getUom() != null) return false;
        if (getUnit() != null ? !getUnit().equals(that.getUnit()) : that.getUnit() != null) return false;
        return getPanel() != null ? getPanel().equals(that.getPanel()) : that.getPanel() == null;
    }

    @Override
    public int hashCode() {
        int result = getOrderNo() != null ? getOrderNo().hashCode() : 0;
        result = 31 * result + (getPlant() != null ? getPlant().hashCode() : 0);
        result = 31 * result + (getMaterial() != null ? getMaterial().hashCode() : 0);
        result = 31 * result + (getMaterialDesc() != null ? getMaterialDesc().hashCode() : 0);
        result = 31 * result + (getItemSpec() != null ? getItemSpec().hashCode() : 0);
        result = 31 * result + (getLower() != null ? getLower().hashCode() : 0);
        result = 31 * result + (getUpper() != null ? getUpper().hashCode() : 0);
        result = 31 * result + (getUom() != null ? getUom().hashCode() : 0);
        result = 31 * result + (getUnit() != null ? getUnit().hashCode() : 0);
        result = 31 * result + (getPanel() != null ? getPanel().hashCode() : 0);
        return result;
    }
}
